package com.ltu.model.request.coupon;

import java.util.Date;

import javax.validation.constraints.NotNull;

import cn.hutool.core.date.DateTime;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.Setter;

@Data
public class CouponByAdminReq {
	@ApiModelProperty(value = " 批次名称 ")
	private String couponBatchName;
	@ApiModelProperty(value = " coupon_name:券名称 ")
	private String couponName;
	@ApiModelProperty(value = " coupon_desc:券详情描述 ")
	private String couponDesc;
//	@ApiModelProperty(value = " coupon_img:券图片 ")
//	private String couponImg;
	@ApiModelProperty(value = " coupon_type:券类型：1礼品兑换券2商品抵扣券3签到券,默认1", required = false)
	private Integer couponType = 1;
	@ApiModelProperty(value = " product_id:可以兑换的商品ID ")
	private Integer productId;
	@ApiModelProperty(value = " product_name:可兑换的商品名称 ")
	private String productName;
//	@ApiModelProperty(value = " banner_img:商品的图片 ")
//	private String bannerImg;
	@ApiModelProperty(value = " convert_amount:单张礼品券可以兑换的数量 ")
	private Integer convertAmount;
	@ApiModelProperty(value = " coupon_price:券价值单位分 ")
	private Integer couponPrice;
	@ApiModelProperty(value = " condition_price:使用时的消费额限制 ")
	private Integer conditionPrice;
	@ApiModelProperty(value = " condition_price_desc:使用费用限制 ")
	private String conditionPriceDesc;
	@ApiModelProperty(value = " amount:总库存 ")
	private Integer amount;
	@ApiModelProperty(value = " surplus_amount:剩余库存 ")
	private Integer surplusAmount;
	@ApiModelProperty(value = " status:状态：0下架1上架 ")
	private Integer status;
	@ApiModelProperty(value = " create_id:创建人 ")
	private Integer createId;

	@ApiModelProperty(value = " coupon_batch_code:我方生成的批次号 ")
	private String couponBatchCode;
	@ApiModelProperty(value = " wx_coupon_code:微信返回的批次号 ")
	private String wxCouponCode;
	
	@ApiModelProperty(value = "只有商家能看的券备注")
	private String adminRemark;
	@ApiModelProperty(value = "兑换开始日期：格式：yyyy-MM-dd hh:mm:ss")
	private Date convertStartDate;
	@ApiModelProperty(value = "兑换结束日期：格式：yyyy-MM-dd hh:mm:ss")
	private Date convertEndDate;
	@ApiModelProperty(value = "用户最多可领几张")
	@NotNull
	private Integer userCouponMax;
	@ApiModelProperty(value = " create_id:创建人 ")
	private Integer companyId;
	
	
	private  void  setAmount(int amount) {
		this.amount=amount;
		this.surplusAmount=amount;
	}
	
	

}
